exist — Test for an argument


\begin{rail}
Exist : 'exist' '(' ( Scalar \vert Matrix \vert List \vert String) ')' ;
\end{rail}
exist is a function that tests whether its argument is actually a legitimate variable or function. If the argument exists, then exist returns 1, or true if you prefer, and returns 0, or false, if the argument doesn't exist. Note that you can't pass a constant value as an argument, and passing an argument that has enough brackets to look like a function, but isn't really a function, gives an error message. This is caused by not being able to evaluate the function. In general, you should be using this function in general purpose user-defined functions to make sure all the neccessary arguments are present, and to provide defaults as appropriate.

Subsections